const path = require("path");
const resolve = dir => {
  return path.join(__dirname, dir);
};

module.exports = {
  baseUrl: "/",
  // 输出文件目录
  outputDir: "dist",
  // eslint-loader 是否在保存的时候检查
  lintOnSave: true,
  chainWebpack: config => {
    config.resolve.alias
      .set("@", resolve("src"))
      .set("_c", resolve("src/components"))
      .set("_conf", resolve("config"));
  },
  devServer: {
    open: true
  }
  // devServer: {
  //   open: true,
  //   proxy: {
  //     "/": {
  //       target: "https://h5.ele.me",
  //       changeOrigin: true,
  //       secure: false
  //     }
  //   }
  // }
};
